
<h1>Items You Have Sent</h1>

<?php 

if($products && sizeof($products)>0) {
	?>
	<table width="100%">
		<tr>
	<?php
	$i=0;
	foreach($products as $p) {
//		$product = $p[]
		$model_name = $p['FacebookAction']['model_name'];
		$product = $p['product'];
//		print_r($product);
		echo '<td style="text-align:center;">';
		echo '<img src="'.$product[$model_name]['thumbnail_image_src'].'" />';
		echo '<br />';
		echo $product[$model_name]['title'];
		echo '</td>';
		$i++;
		if($i%3==0) {
			echo "</tr><tr>";
		}
		
	}
	?>
		</tr>
	</table>
	<?php
}

?>
